home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-11 / ksgclock.zip / TEST1.PRG < prev    next >
Text File  |  1992-08-20  |  3KB  |  54 lines

  1.                                                                                      /*
  2. ┌───────────────────────────────────────────────────────────────────────┐
  3. │  Program Name: TEST.PRG          Copyright: Gallagher Computing Corp. │▐
  4. │  Date Created: 08/11/92           Language: Clipper 5.0               │▐
  5. │  Time Created: 00:39:14             Author: Kevin S Gallagher  .PRG   │▐
  6. │  c:/brief/clipper.src               Author: Ben Echols         .ASM   │▐
  7. │  What it does: Places a clock on the display screen.                  │▐                                     │▐
  8. │  Files needed: TICKER.OBJ                                             │▐          │▐
  9. │  RETURN CODES:                                                        │▐
  10. │  - 100     successful                                                 │▐
  11. │  -  99     col out of range                                           │▐
  12. │  -  98     row out of range                                           │▐
  13. │  -  97     already installed / not installed                          │▐
  14. │                                                                       │▐
  15. │ LIMITATIONS:                                                          │▐
  16. │ NONE                                                                  │▐
  17. │ Kevin S. Gallagher   660 Woodward Drive  Huntingdon Vlly. PA 19006    │▐
  18. │ CIS: 70034,2313                                                       │▐
  19. └───────────────────────────────────────────────────────────────────────┘▐
  20.   ▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀           */
  21.  
  22. function testclock
  23.     local x
  24.     scroll()
  25.     @0,0 say PADR(" ",80) color 'w+/rb'
  26.     @MAXROW(),0 say PADR(" PRESS ANY KEY TO EXIT...",80) color "W+/RB"
  27.     CLOCK(0,71)                                //── install clock
  28.     inkey(0)
  29.     x := CLOCK()                                //── remove and get errorlevel
  30.     @ maxrow(),0 say PADR(" Clock returned "+ltrim(str(x)),80) color "W+/RB"
  31. return nil
  32.  
  33. //////////////////////////////////////////////////////////////////////////
  34. // Syntax:  BK_TICKINS(<nRow>,<nCol>) --> nErrorLevel
  35. //          Where <nRow> is the row to position the clock   0 - 24
  36. //                <nCol> is the column to place the clock   0 - 72
  37. //
  38. //          BK_TICKREM() -->nErrorLevel
  39. //          Used to remove the clock
  40. //
  41. // Returns:  100 if successful
  42. //            99 column out of range
  43. //            98 Row out of range
  44. //            97 Already installed/not installed
  45. //
  46. // The function below is one of many ways to invoke the clock, use whatever
  47. // method you like to use!
  48. //
  49. //////////////////////////////////////////////////////////////////////////
  50. function CLOCK(nRow,nCol)
  51.     local x:=IF(nRow==NIL.OR.nCol==NIL,BK_TICKREM(),BK_TICKINS(nRow, nCol))
  52. return x
  53.  
  54.